package mymyoux.io.sql
{
	import flash.data.SQLResult;
	import flash.errors.SQLError;
	import flash.events.SQLErrorEvent;

	public class SQLQueryEvent
	{
		private var _result:SQLResult;
		private var _error:SQLError
		public function SQLQueryEvent(result:SQLResult, error:SQLError = null)
		{
			_result = result;
			_error = error;
		}

		public function get error():SQLError
		{
			return _error;
		}

		public function get result():SQLResult
		{
			return _result;
		}
		public function get success():Boolean
		{
			return _result != null && _error == null;
		}
		public function get isError():Boolean
		{
			return !success;
		}

	}
}